package com.cykj.pos.controller.api;

import com.cykj.common.core.domain.AjaxResult;
import com.cykj.pos.domain.BizMerchTransactions;
import com.cykj.pos.domain.BizMerchant;
import com.cykj.pos.profit.dto.TransDataDTO;
import com.cykj.pos.service.IBizMerchTransactionsService;
import com.cykj.pos.service.IBizMerchantService;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


@RestController
@RequestMapping("/pos/api/v2/transData")
@RequiredArgsConstructor(onConstructor_ = @Autowired)
public class PosV2AppTransDataController {
    private final IBizMerchantService merchantService;
    private final IBizMerchTransactionsService iBizMerchTransactionsService;

    /**
     * 線上pos交易明細
     * @return
     */
    @PostMapping("/getOnlineDetail")
    public AjaxResult getOnlineDetail(@RequestBody TransDataDTO transDataDTO){
        //查询当前登录商户信息
        return iBizMerchTransactionsService.getOnlineDetail(transDataDTO);
    }
}
